package com.changdu.seatunnel.admin.pojo;

import java.util.Objects;

import com.changdu.seatunnel.admin.config.enums.SyncTaskStatus;

import lombok.Data;

@Data
public class SeatunnelTaskInfo {

	private String jobId;
	
	private String jobName;
	
	private String jobStatus;
	
	private String createTime;
	
	private Long sinkWriteCount;
	
	private Double sinkWriteQPS;
	
	private Long sourceReceivedCount;
	
	private Double sourceReceivedQPS;
	
	public SyncTaskStatus taskStatus() {
		return SyncTaskStatus.fromSeatunnelStatus(Objects.nonNull(jobStatus) ? jobStatus : "");
	}
	
}
